<template>
  <div class="index-join" @click="close">
    <div class="wrap" ref="wrap">
      <img class="close" src="/close.png" alt="图片加载失败" @click="$emit('hideJoin')">
      <img class="head" src="/dddd.png" alt="图片加载失败">
      <p class="title">Join the mining pool and start earning</p>
      <p class="desc">You need to pay a miner's fee to receive the voucher and an adress is only allowed to receive it
        once</p>
      <div class="btn-box">
        <div class="cancel">Cancel</div>
        <div class="accept">Accept</div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data () {
    return {

    }
  },
  methods: {
    close (e) {
      if (e.target === e.currentTarget) {
        this.$emit('hideJoin')
      }
    }
  }
}
</script>

<style lang="scss" >
.index-join {
  position: fixed;
  width: 100%;
  height: 100vh;
  top: 0;
  left: 0;
  overflow: hidden;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 9999999;
  width: 100%;

  .wrap {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 380px;
    border-radius: 7px 7px 0px 0px;
    color: #303133;
    font-size: 14px;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    padding: 12px 0 20px 0;
    transition: all 0.35s ease-in-out 0s;

    .close {
      width: 20px;
      height: 20px;
      position: absolute;
      z-index: 3;
      top: 15px;
      right: 15px;
      font-size: 20px;
      font-weight: normal;
      color: rgb(0, 0, 0);
    }

    .head {
      width: 188px;
      height: 146px;
      margin: 0 auto;
    }

    .title {
      font-weight: 600;
      color: #333;
      font-size: 18px;
      margin-bottom: 15px;
      margin-top: 4px;
      text-align: center;
    }

    .desc {
      font-size: 16px;
      color: #999;
      text-align: center;
      line-height: 21px;
    }

    .btn-box {
      display: flex;
      justify-content: space-between;
      align-items: center;
      width: 100%;
      height: 100%;
      padding: 20px 15px;

      .cancel {
        width: 160px;
        height: 54px;
        border-radius: 12px 12px 12px 12px;
        font-size: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: rgb(0, 82, 255);
        border: 1px solid #c4c4c4;
      }

      .accept {
        width: 160px;
        height: 54px;
        border-radius: 12px 12px 12px 12px;
        font-size: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 160px;
        height: 54px;
        border-radius: 12px 12px 12px 12px;
        font-size: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #fff;
        background-color: rgb(1, 98, 255);
      }
    }
  }
}
</style>
